// -----------------------------------------------------------------------
//  <copyright file="ValidateCodeController.cs" company="LiuliuSoft">
//      Copyright (c) 2022-2024 DaprPlus. All rights reserved.
//  </copyright>
//  <site>https://dapr.plus</site>
//  <last-editor>郭明锋</last-editor>
//  <last-date>2024/12/7 19:30:56</last-date>
// -----------------------------------------------------------------------

using DaprPlus.Identity.Application.Identity.Users.Commands;


namespace DaprPlus.Identity.Api.Controllers
{
    public class ValidateCodeController : ApiControllerBase
    {
        [HttpPost()]
        [Produces<ApiResult>]
        public async Task<ActionResult> SendValidateCode([FromBody] SendValidateCodeCommand command)
        {
            var mediator = HttpContext.RequestServices.GetRequiredService<IMediator>();
            var result = await mediator.Send(command);
            return Ok(result);
        }

    }
}
